package cn.wolfcode.luowowo.comment.domain;

import lombok.Getter;
import lombok.Setter;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;
import java.util.Date;

@Getter@Setter
@Document("travel_comment")
public class TravelComment implements Serializable {
    public static final Integer TRAVEL_NOMAL_TYPE = 0; //普通评论
    public static final Integer TRAVEL_COMMENT_TYPE = 1; //回复评论

    @Id
    private String id; //文档id

    private Long travelId; //游记id

    private String travelTitle; //游记文章

    private Long userId; //当前用户id

    private String username; //用户昵称

    private Integer level; //用户等级

    private String headUrl; //用户头像

    private Integer type = TRAVEL_NOMAL_TYPE; //评论类型

    private Date createTime; //评论时间

    private String content; //评论内容

    private TravelComment refComment; //引用评论
}
